<?php

/**
 * logout.php
 * @package versionManager
 * @filesource
 */

/*	Close the backdoor	*/
$curPage = strtoupper($_SERVER['PHP_SELF']);
if (isset($curPage) && strpos($curPage, 'INDEX.PHP') === false)
    header('Location:./index.php');

require_once (CLASS_PATH . 'template.class.php');

/*	load the page header	*/
$header = new template(TEMPLATE_PATH . 'header.tpl');
$header->replace('&&SIDEMENU&&', '');
$header->replace('&&STYLE&&', '');
$header->replace('&&USER&&', '');

/*  Close Session */
$session->closeSession();

/*	Echo the page	*/
echo $header->templateHtml;


if ($session->loggedIn == false)
    echo "<H2>You have been logged out</h2><br/>Click <a href='index.php'>here</a> to login again";

?>
